Small tweaks
authorMatthias Clasen <matthiasc@src.gnome.org>
Thu, 1 Jun 2006 16:41:40 +0000 (16:41 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Thu, 1 Jun 2006 16:41:40 +0000 (16:41 +0000)
ChangeLog
ChangeLog.pre-2-10
tests/testnotebookdnd.c

index 70b2e0515cba5150b7cef0f37382e8f39a90ae2c..5fc1fc1cb50f92b5ca90d53d7a74eebd72700249 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,6 @@
 2006-06-01  Matthias Clasen  <mclasen@redhat.com>
+       
+       * tests/testnotebookdnd.c: Small tweaks to test more things.
 
        * gtk/gtktoolbutton.c (gtk_tool_button_class_init): Add
        an icon-spacing style property for the same purpose.
index 70b2e0515cba5150b7cef0f37382e8f39a90ae2c..5fc1fc1cb50f92b5ca90d53d7a74eebd72700249 100644 (file)
@@ -1,4 +1,6 @@
 2006-06-01  Matthias Clasen  <mclasen@redhat.com>
+       
+       * tests/testnotebookdnd.c: Small tweaks to test more things.
 
        * gtk/gtktoolbutton.c (gtk_tool_button_class_init): Add
        an icon-spacing style property for the same purpose.
index f47d93a6f2bfd0d1199b18053e0bc42851f85150..39d72b822712f87d9e86c68649b484d22d87c22f 100644 (file)
@@ -109,12 +109,15 @@ on_notebook_drag_begin (GtkWidget      *widget,
 
   page_num = gtk_notebook_get_current_page (GTK_NOTEBOOK (widget));
 
-  pixbuf = gtk_widget_render_icon (widget,
-                                  (page_num % 2) ? GTK_STOCK_HELP : GTK_STOCK_STOP,
+  if (page_num > 2)
+    {
+      pixbuf = gtk_widget_render_icon (widget,
+                                  (page_num % 2) ? GTK_STOCK_HELP : GTK_STOCK_STOP,
                                   GTK_ICON_SIZE_DND, NULL);
 
-  gtk_drag_set_icon_pixbuf (context, pixbuf, 0, 0);
-  g_object_unref (pixbuf);
+      gtk_drag_set_icon_pixbuf (context, pixbuf, 0, 0);
+      g_object_unref (pixbuf);
+    }
 }
 
 static void